package course.dmsSpringBoot.entity;

/**
 * Author：zouran
 * Date：2023/3/30  14:04
 * Description: enum of code and message
 */
public enum CodeEnum {
 SUCCESS(200,"success"),
 ERROR_EARTHQUAKEID(200,"地震不存在!"),
 ERROR_PATH(404,"The requested resource is not available"),
 ERROR_SERVER(500,"系统错误!"),
 TIMEOUT(408,"系统繁忙，请稍后再试"),
 ERROR_COOKIE(403,"cookie校验失败"),
 ERROR_PARAM(400,"invalid request params");
 private final int code;
 private final String message;
 CodeEnum(int code, String message) {
  this.code = code;
  this.message = message;
 }
 public int getCode() {
  return code;
 }

 public String getMessage() {
  return message;
 }
}
